Skip to content

Conversation

@jprieto-temporal
Copy link
Contributor

What changed?

Replaced the plain int32 status field in the namespace registry with atomic.Int32. Updated Start() and Stop() to use the type's methods instead of package-level atomic functions.

Why?

Using atomic.Int32 is more type-safe and idiomatic in modern Go.

How did you test it?

  • built
  • run locally and tested manually
  • covered by existing tests
  • added new unit test(s)
  • added new functional test(s)

Potential risks

None. This is a mechanical refactor with identical runtime behavior.

@jprieto-temporal jprieto-temporal requested review from a team as code owners January 6, 2026 18:15
Copy link
Contributor

@dnr dnr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should remove this atomic status pattern entirely. I've been removing it from modules that I touch. All lifecycle management for objects with process-lifetime should be done through fx, which serializes all Start/Stop calls. (Objects with other lifetimes may need other approaches.)

@jprieto-temporal
Copy link
Contributor Author

@dnr i agree: #8948

@jprieto-temporal jprieto-temporal deleted the jprieto/lnnpvmwzytur branch January 12, 2026 21:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants